/************************************************************************

								Heroes IV
					  Copyright 2000, The 3DO Company

	------------------------------------------------------------------
  						       triggerable_event.h

	$Header: /game/triggerable_event.h $

	$NoKeywords: $

 ************************************************************************/

#if !defined( TRIGGERABLE_EVENT_H_INCLUDED )
#define TRIGGERABLE_EVENT_H_INCLUDED

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#include <string>

#include "discrete_event.h"

// --------------------------------------------------------------------------
// t_triggerable_event class
// --------------------------------------------------------------------------

class t_triggerable_event : public t_discrete_event
{
public:
	// Destructor
	virtual ~t_triggerable_event() = 0;

	// Member functions
	std::string const &	get_name() const;
	void				set_name( std::string const & new_name );

protected:
	// Member functions
	bool	read( std::streambuf & stream, int version );
	bool	read_from_map( std::streambuf & stream, int format_version );
	bool	write( std::streambuf & stream ) const;

private:
	// Data members
	std::string	m_name;
};

// --------------------------------------------------------------------------
// t_triggerable_event inline members
// --------------------------------------------------------------------------

// --------------------------------------------------------------------------
// --------------------------------------------------------------------------
inline t_triggerable_event::~t_triggerable_event()
{
}

// --------------------------------------------------------------------------
// --------------------------------------------------------------------------
inline std::string const & t_triggerable_event::get_name() const
{
	return m_name;
}

// --------------------------------------------------------------------------
// --------------------------------------------------------------------------
inline void t_triggerable_event::set_name( std::string const & new_name )
{
	m_name = new_name;
}

#endif // !defined( TRIGGERABLE_EVENT_H_INCLUDED )
